package net.lab1024.sa.base.module.support.config;

import jakarta.annotation.Resource;
import net.lab1024.sa.base.common.controller.SupportBaseController;
import net.lab1024.sa.base.common.domain.R;
import net.lab1024.sa.base.module.support.config.domain.ConfigVO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * 配置
 *
 * @Author 1024创新实验室-主任: 卓大
 * @Date 2022-03-14 20:46:27
 * @Wechat zhuoda1024
 * @Email lab1024@163.com
 * @Copyright  <a href="https://1024lab.net">1024创新实验室</a>
 */
// API接口分组
@RestController
public class ConfigController extends SupportBaseController {

    @Resource
    private ConfigService configService;

    // 查询配置详情 @author 卓大
    @GetMapping("/config/queryByKey")
    public R<ConfigVO> queryByKey(@RequestParam String configKey) {
        return R.ok(configService.getConfig(configKey));
    }

}
